style context: Don't leak a widget path
authorMatthias Clasen <mclasen@redhat.com>
Fri, 18 Nov 2016 01:22:42 +0000 (20:22 -0500)
committerMatthias Clasen <mclasen@redhat.com>
Fri, 18 Nov 2016 01:22:42 +0000 (20:22 -0500)
Found by valgrind.

gtk/gtkstylecontext.c

index df934e05291655f92c8a57384ac25377ea2f9146..09c0a1b2ab797a87341e1299fdab64acb6535c98 100644 (file)
@@ -1389,6 +1389,8 @@ _gtk_style_context_peek_style_property (GtkStyleContext *context,
                                                  gtk_widget_path_iter_get_state (path, -1),
                                                  pspec, &pcache->value))
         {
+          gtk_widget_path_unref (path);
+
           return &pcache->value;
         }
     }